import axios from 'axios'

const request = axios.create({
  baseURL:'http://cba.itlike.com/public/index.php?s=/api',
  timeout:10000
})

// 请求拦截器
request.interceptors.response.use(function(config){
  return config
},function(error){
  return Promise.reject(error)
})
// 响应拦截器
request.interceptors.response.use(function(response){
  return response.data
},function(error){
  return Promise.reject(error)
})

export default request